Analysis date: 2022-12-13

Depends on

DIPG_FirstBatch_DataProcessing Script

load("../Data/Cache/Xenografts_Batch1_DataProcessing.RData")

TODO

Setup

Load libraries and functions

Quality control

Nr. phospho sites

print( paste( nrow(pY_Set1) , "pY peptides passed the filtering procedure for Set 1. These peptides were detected from", length(unique(pY_Set1$HGNC_Symbol) ), "proteins." ))
## [1] "236 pY peptides passed the filtering procedure for Set 1. These peptides were detected from 159 proteins."
#print( paste( nrow(pST_Set1) , "pST peptides passed the filtering procedure for Set 1. These peptides were detected from", length(unique(pST$HGNC_Symbol) ), "proteins." ))

print( paste( nrow(pY_Set2) , "pY peptides passed the filtering procedure for Set 2. These peptides were detected from", length(unique(pY_Set2$HGNC_Symbol) ), "proteins." ))
## [1] "573 pY peptides passed the filtering procedure for Set 2. These peptides were detected from 362 proteins."
#print( paste( nrow(pST_Set2) , "pST peptides passed the filtering procedure for Set 2. These peptides were detected from", length(unique(pST$HGNC_Symbol) ), "proteins." ))

print( paste( nrow(pY_Set3) , "pY peptides passed the filtering procedure for Set 2. These peptides were detected from", length(unique(pY_Set3$HGNC_Symbol) ), "proteins." ))
## [1] "266 pY peptides passed the filtering procedure for Set 2. These peptides were detected from 177 proteins."
print( paste( nrow(pY_noNA) , "pY peptides passed the filtering procedure for the sets combined. These peptides were detected from", length(unique(pY_noNA$HGNC_Symbol) ), "proteins." ))
## [1] "155 pY peptides passed the filtering procedure for the sets combined. These peptides were detected from 112 proteins."
#print( paste( nrow(pST_noNA) , "pST peptides passed the filtering procedure for the sets combined. These peptides were detected from", length(unique(pST_noNA$HGNC_Symbol) ), "proteins." ))

Nr. proteins whole proteome

print( paste( length(unique(prot_Set1$HGNC_Symbol) ), "proteins detected in Set 1." ))
print( paste( length(unique(prot_Set2$HGNC_Symbol) ), "proteins detected in Set 2." ))

print( paste( length(unique(prot_top3peptidemedian$HGNC_Symbol) ), "proteins detected in both Sets." ))

Distributions

pY Abundances

Set 1

pY_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")
## Warning: Removed 303 rows containing non-finite values (stat_density).

pY_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Abundances normalised to sup")
## Warning: Removed 303 rows containing non-finite values (stat_density).

pY_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

pY_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

pY_Set1 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Set 2

pY_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")
## Warning: Removed 645 rows containing non-finite values (stat_density).

pY_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Abundances normalised to sup")
## Warning: Removed 633 rows containing non-finite values (stat_density).

pY_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

pY_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

pY_Set2 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Set 3

pY_Set3 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")
## Warning: Removed 493 rows containing non-finite values (stat_density).

pY_Set3 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Abundances normalised to sup")
## Warning: Removed 493 rows containing non-finite values (stat_density).

pY_Set3 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

pY_Set3 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

pY_Set3 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Combined

pY_noNA %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_"), drop = F) %>%
  separate( Sample , into = c("xenograft", "treatment", "day", "replicate", "set"), sep = "_", remove = F) %>%
  ggplot(aes(value, fill= treatment, group = Sample)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to normal") +
  theme_bw() +
  scale_fill_manual(values = PGPalette[c(1, 2, 4, 5)])

pY_noNA %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_")) %>%
  separate( Sample , into = c( "xenograft", "treatment", "day", "replicate", "set"), sep = "_", remove = F) %>%
  ggplot(aes(Sample, value, fill= treatment)) +
  geom_boxplot() +
  ggtitle("log2FC to normal") +
  theme_bw() +
  theme(axis.text.x = element_text(angle = 90)) +
  scale_fill_manual(values = PGPalette[c(1, 2, 4, 5)])

pST Abundances

Set 1

pST_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")

pST_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Abundances normalised to sup")

pST_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

pST_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

pST_Set1 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Set 2

pST_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")

pST_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Abundances normalised to sup")

pST_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

pST_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

pST_Set2 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Combined

pST_noNA %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_")) %>%
  separate(Sample, into = c("treatment", "replicate"), remove = F) %>%
  ggplot(aes(value, fill= treatment, group = Sample)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to normal") +
  theme_bw() +
  scale_fill_manual(values = PGPalette[c(1, 2, 4, 5)]) +
  geom_vline(xintercept = 0)

pST_noNA %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_")) %>%
  separate(Sample, into = c("treatment", "replicate"), remove = F) %>%
  ggplot(aes(Sample, value, fill= treatment)) +
  geom_boxplot() +
  ggtitle("log2FC to bridge") +
  theme_bw() +
  theme(axis.text.x = element_text(angle = 90)) +
  scale_fill_manual(values = PGPalette[c(1, 2, 4, 5)])

pST_noNA %>%
  select(contains("log2FC")) %>%
  select(!contains("normal")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_")) %>%
  separate(Sample, into = c("treatment", "replicate"), remove = F) %>%
  ggplot(aes(value, fill= treatment, group = Sample)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to normal") +
  theme_bw() +
  scale_fill_manual(values = PGPalette[c(1, 2, 5)])

Whole proteome abundances

Set 1

prot_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  geom_density(alpha=0.5) +
  xlim(0,10e5) +
  ggtitle("Raw abundances")

prot_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10) +
  ggtitle("Abundances normalised to sup")

prot_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

prot_Set1 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

prot_Set1 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Set 2

prot_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e5) +
  ggtitle("Raw abundances")

prot_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10) +
  ggtitle("Abundances normalised to sup")

prot_Set2 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Raw abundances")

prot_Set2 %>%
  select(contains("TMTNorm_Abundance")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  scale_x_log10() +
  ggtitle("Abundances normalised to sup")

prot_Set2 %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to bridge")

Combined

prot_top3peptidemedian %>%
  select(contains("log2FC")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to normal")

prot_top3peptidemedian %>%
  select(contains("log2FC")) %>%
  select(!contains("normal")) %>%
  pivot_longer(names_to = "Sample", cols = everything()) %>%
  mutate(Sample = str_remove(Sample, "log2FC_")) %>%
  separate(Sample, into = c("treatment", "replicate"), remove = F) %>%
  ggplot(aes(value, fill= treatment, group = Sample)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  ggtitle("log2FC to normal") +
  theme_bw() +
  scale_fill_manual(values = PGPalette[c(1, 2, 5)])

t(pST_mat_nonormal) %>%
  as.data.frame(  ) %>%
  rownames_to_column( "peptide") %>%
  pivot_longer(-peptide, names_to = "sample", values_to = "log2FC") %>%
  mutate(sample = gsub( "log2FC_", "", sample)) %>%
  separate(sample, into = c("treatment", "replicate"), sep = "-",remove = F)   %>%
  separate(peptide, into = c("HGNC_Symbol", "Annotated_Sequence"), sep =   "_", remove = F ) %>%
  group_by(sample, treatment, replicate) %>%
  summarise("Mean of patient" = mean(log2FC)) %>%
  ungroup() %>%
  mutate(treatment = as.factor(treatment)) %>%
  mutate(treatment = factor(treatment, levels = c("WT", "G34R", "K27M"))) %>%
  ggplot(aes( treatment, `Mean of patient`, fill = treatment )) +
  geom_boxplot(outlier.size = 0) +
  theme_bw() +
  theme(axis.text.x = element_text(angle = 90),
  axis.title.x = element_blank()) +
  scale_fill_manual(values = PGPalette[c(5,1,2)]) +
  ggbeeswarm::geom_beeswarm() +
  ggpubr::stat_compare_means(method = "t.test",
  comparisons = list(c("WT", "G34R"),
  c("WT", "K27M"),
  c("K27M", "G34R")) ) +
  ggtitle("pST median normalised log2 fold change")

pY Mean-Variance Relationship

Set 1

pY_Set1 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  group_by(peptide) %>%
  summarise(mean = mean(value), sd = sd (value) ) %>%
  ggplot(aes(mean, sd)) +
  xlim(0,10e4) +
  ylim(0,10e4) +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## Warning: Removed 20 rows containing non-finite values (stat_cor).
## `geom_smooth()` using formula 'y ~ x'
## Warning: Removed 20 rows containing non-finite values (stat_smooth).
## Warning: Removed 20 rows containing missing values (geom_point).

pY_Set1 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  mutate(log2value = log2(value) ) %>%
  group_by(peptide) %>%
  summarise(meanlog2 = mean(log2value), sdlog2 = sd (log2value) ) %>%
  ggplot(aes(meanlog2, sdlog2)) +
  #ylim(0,10e4) +
  #scale_x_log10() +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## `geom_smooth()` using formula 'y ~ x'

Set 2

pY_Set2 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  group_by(peptide) %>%
  summarise(mean = mean(value), sd = sd (value) ) %>%
  ggplot(aes(mean, sd)) +
  xlim(0,10e4) +
  ylim(0,10e4) +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## Warning: Removed 44 rows containing non-finite values (stat_cor).
## `geom_smooth()` using formula 'y ~ x'
## Warning: Removed 44 rows containing non-finite values (stat_smooth).
## Warning: Removed 44 rows containing missing values (geom_point).

pY_Set2 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  mutate(log2value = log2(value) ) %>%
  group_by(peptide) %>%
  summarise(meanlog2 = mean(log2value), sdlog2 = sd (log2value) ) %>%
  ggplot(aes(meanlog2, sdlog2)) +
  #ylim(0,10e4) +
  #scale_x_log10() +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## `geom_smooth()` using formula 'y ~ x'

Set 3

pY_Set3 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  group_by(peptide) %>%
  summarise(mean = mean(value), sd = sd (value) ) %>%
  ggplot(aes(mean, sd)) +
  xlim(0,10e4) +
  ylim(0,10e4) +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## Warning: Removed 32 rows containing non-finite values (stat_cor).
## `geom_smooth()` using formula 'y ~ x'
## Warning: Removed 32 rows containing non-finite values (stat_smooth).
## Warning: Removed 32 rows containing missing values (geom_point).

pY_Set3 %>%
  mutate(peptide = paste0( HGNC_Symbol, "_", `Annotated Sequence` )) %>%
  select(peptide, contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = -peptide) %>%
  mutate(log2value = log2(value) ) %>%
  group_by(peptide) %>%
  summarise(meanlog2 = mean(log2value), sdlog2 = sd (log2value) ) %>%
  ggplot(aes(meanlog2, sdlog2)) +
  #ylim(0,10e4) +
  #scale_x_log10() +
  #geom_histogram(bins= 200) +
  geom_point() +
  ggtitle("pY sd vs. mean") +
  ggpubr::stat_cor()+
  geom_smooth(method = "lm")
## `geom_smooth()` using formula 'y ~ x'

pY Abundances per peptide

Set 1

pY_Set1 %>%
  select(contains("Abundance"), -contains("TMT")) %>%
  pivot_longer(names_to = "Channel", cols = everything()) %>%
  ggplot(aes(value, fill= Channel)) +
  #geom_histogram(bins= 200) +
  geom_density(alpha=0.5) +
  xlim(0,10e4) +
  ggtitle("Raw abundances")
## Warning: Removed 303 rows containing non-finite values (stat_density).

Session Info

sessionInfo()
## R version 4.1.3 (2022-03-10)
## Platform: x86_64-apple-darwin17.0 (64-bit)
## Running under: macOS Big Sur/Monterey 10.16
## 
## Matrix products: default
## BLAS:   /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRblas.0.dylib
## LAPACK: /Library/Frameworks/R.framework/Versions/4.1/Resources/lib/libRlapack.dylib
## 
## locale:
## [1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8
## 
## attached base packages:
## [1] stats4    stats     graphics  grDevices utils     datasets  methods  
## [8] base     
## 
## other attached packages:
##  [1] forcats_0.5.2               stringr_1.4.1              
##  [3] dplyr_1.0.10                purrr_0.3.5                
##  [5] readr_2.1.3                 tidyr_1.2.1                
##  [7] tibble_3.1.8                ggplot2_3.3.6              
##  [9] tidyverse_1.3.2             mdatools_0.13.0            
## [11] SummarizedExperiment_1.24.0 GenomicRanges_1.46.1       
## [13] GenomeInfoDb_1.30.1         MatrixGenerics_1.6.0       
## [15] matrixStats_0.62.0          DEP_1.16.0                 
## [17] org.Hs.eg.db_3.14.0         AnnotationDbi_1.56.2       
## [19] IRanges_2.28.0              S4Vectors_0.32.4           
## [21] Biobase_2.54.0              BiocGenerics_0.40.0        
## [23] fgsea_1.20.0               
## 
## loaded via a namespace (and not attached):
##   [1] utf8_1.2.2             shinydashboard_0.7.2   proto_1.0.0           
##   [4] gmm_1.7                tidyselect_1.2.0       RSQLite_2.2.18        
##   [7] htmlwidgets_1.5.4      grid_4.1.3             BiocParallel_1.28.3   
##  [10] norm_1.0-10.0          munsell_0.5.0          codetools_0.2-18      
##  [13] preprocessCore_1.56.0  chron_2.3-58           DT_0.26               
##  [16] withr_2.5.0            colorspace_2.0-3       highr_0.9             
##  [19] knitr_1.40             rstudioapi_0.14        ggsignif_0.6.4        
##  [22] mzID_1.32.0            labeling_0.4.2         GenomeInfoDbData_1.2.7
##  [25] bit64_4.0.5            farver_2.1.1           vctrs_0.5.0           
##  [28] generics_0.1.3         xfun_0.34              R6_2.5.1              
##  [31] doParallel_1.0.17      clue_0.3-62            MsCoreUtils_1.6.2     
##  [34] bitops_1.0-7           cachem_1.0.6           DelayedArray_0.20.0   
##  [37] assertthat_0.2.1       promises_1.2.0.1       scales_1.2.1          
##  [40] googlesheets4_1.0.1    gtable_0.3.1           affy_1.72.0           
##  [43] sandwich_3.0-2         rlang_1.0.6            mzR_2.28.0            
##  [46] splines_4.1.3          GlobalOptions_0.1.2    rstatix_0.7.0         
##  [49] gargle_1.2.1           impute_1.68.0          broom_1.0.1           
##  [52] BiocManager_1.30.19    yaml_2.3.6             abind_1.4-5           
##  [55] modelr_0.1.9           backports_1.4.1        httpuv_1.6.6          
##  [58] tools_4.1.3            affyio_1.64.0          ellipsis_0.3.2        
##  [61] gplots_3.1.3           jquerylib_0.1.4        RColorBrewer_1.1-3    
##  [64] STRINGdb_2.6.5         MSnbase_2.20.4         gsubfn_0.7            
##  [67] Rcpp_1.0.9             hash_2.2.6.2           plyr_1.8.7            
##  [70] zlibbioc_1.40.0        RCurl_1.98-1.9         ggpubr_0.4.0          
##  [73] sqldf_0.4-11           GetoptLong_1.0.5       zoo_1.8-11            
##  [76] haven_2.5.1            cluster_2.1.4          fs_1.5.2              
##  [79] magrittr_2.0.3         data.table_1.14.4      circlize_0.4.15       
##  [82] reprex_2.0.2           googledrive_2.0.0      pcaMethods_1.86.0     
##  [85] mvtnorm_1.1-3          ProtGenerics_1.26.0    hms_1.1.2             
##  [88] mime_0.12              evaluate_0.17          xtable_1.8-4          
##  [91] XML_3.99-0.12          readxl_1.4.1           gridExtra_2.3         
##  [94] shape_1.4.6            compiler_4.1.3         KernSmooth_2.23-20    
##  [97] ncdf4_1.19             crayon_1.5.2           htmltools_0.5.3       
## [100] mgcv_1.8-41            later_1.3.0            tzdb_0.3.0            
## [103] lubridate_1.8.0        DBI_1.1.3              dbplyr_2.2.1          
## [106] ComplexHeatmap_2.10.0  MASS_7.3-58.1          tmvtnorm_1.5          
## [109] Matrix_1.5-1           car_3.1-1              cli_3.4.1             
## [112] vsn_3.62.0             imputeLCMD_2.1         parallel_4.1.3        
## [115] igraph_1.3.5           pkgconfig_2.0.3        MALDIquant_1.21       
## [118] xml2_1.3.3             foreach_1.5.2          bslib_0.4.0           
## [121] XVector_0.34.0         rvest_1.0.3            digest_0.6.30         
## [124] Biostrings_2.62.0      rmarkdown_2.17         cellranger_1.1.0      
## [127] fastmatch_1.1-3        shiny_1.7.3            gtools_3.9.3          
## [130] rjson_0.2.21           nlme_3.1-160           lifecycle_1.0.3       
## [133] jsonlite_1.8.3         carData_3.0-5          limma_3.50.3          
## [136] fansi_1.0.3            pillar_1.8.1           lattice_0.20-45       
## [139] KEGGREST_1.34.0        fastmap_1.1.0          httr_1.4.4            
## [142] plotrix_3.8-2          glue_1.6.2             png_0.1-7             
## [145] iterators_1.0.14       bit_4.0.4              stringi_1.7.8         
## [148] sass_0.4.2             blob_1.2.3             caTools_1.18.2        
## [151] memoise_2.0.1
knitr::knit_exit()